<?php

namespace partner\functions\wechat\lib;


use partner\functions\wechat\lib\BaseWechatPartner;
use Exception;

class BusinessInfo extends BaseWechatPartner
{
    // 商户简称
    public $merchant_shortname;

    // 客服电话
    public $service_phone;

    public $sales_info;

    public function setMerchantShortName(string $merchant_shortname)
    {
        if (empty($merchant_shortname))
            throw new Exception("商户简称不能为空");

        $this->merchant_shortname = $merchant_shortname;
        return $this;
    }

    public function setServicePhone(string $service_phone)
    {
        if (empty($service_phone))
            throw new Exception("客服电话不能为空");

        $this->service_phone = $service_phone;
        return $this;
    }

    public function setSalesInfo(SaleInfo $sale_info)
    {
        $this->sale_info = $sale_info;
        return $this;
    }

}